def square_root_bisection(num, tolerance=0.01, iteration=10):
  if num < 0:
    raise ValueError("Square root of negative number is not defined in real numbers")
  elif num in [0, 1]:
    print(f'The square root of {num} is {num}')
    return num
  else:
    left = 0
    right = num if num > 1 else 1
    mid = (left + right) / 2
    for _ in range(iteration):
      if mid**2 < num:
        left = mid
      else:
        right = mid
      if right - left <= tolerance:
        print(f'The square root of {num} is approximately {mid}')
        return mid
      mid = (left + right) / 2
    print(f"Failed to converge within {iteration} iterations")

if __name__ == '__main__':
  square_root_bisection(0.001, 1e-7, 50)
  square_root_bisection(0.25, 1e-7, 50)